package top.stacktrace.binfo;

import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.web.bind.annotation.PostMapping;
import org.springframework.web.bind.annotation.RestController;

import java.util.List;

@RestController
public class BookController {
    @Autowired
    private BookListService bookService;

    @PostMapping("/books")
    public List<Book> getBooks(){
        return bookService.getBooks();
    }
}
